<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no, minimal-ui" />
    <meta content="yes" name="apple-mobile-web-app-capable" />
    <meta content="black" name="apple-mobile-web-app-status-bar-style" />
    <meta name="format-detection" content="telephone=no" />
    <script>
	    var html = document.getElementsByTagName('html')[0];
	    html.style.fontSize = html.clientWidth / 3.75 + "px";
    </script>
    <title>农庄详情</title>
    <link rel="stylesheet" href="../static/css/Reset.css">
    <link rel="stylesheet" href="../static/css/yellowPage_detail.css">   
    <link rel="stylesheet" href="../libs/swiper/swiper.min.css">
</head>
<body>
	<div class="wz_wrapper">
		
	</div>
	<!--loading-->
	<div class="loading_modal">
		<img src="http://static.sheyuan.com/FrontEnd/test/wx3.0/images/loading.gif">
		<p>正在加载···</p>
	</div>
	<input type="hidden" name="token" id="token" value="" />
</body>
	<script src="https://api.map.baidu.com/api?v=2.0&ak=HuWMDRmExUdhWoXsVSnBgqdvtWzhgfDY&s=1"></script>
	<script type="text/javascript" src="../libs/jquery.min.js"></script>
    <script type="text/javascript" src="../libs/fastclick.min.js"></script>
    <script type="text/javascript" src="../libs/vue/vue.min.js"></script>
	<script type="text/javascript" src="../libs/vue/vue-resource.min.js"></script>
    <script type="text/javascript" src="../libs/underscore.js"></script>
    <script type="text/javascript" src="../libs/underscore.extend.js"></script>
   	<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
    <script type="text/javascript" src="../libs/require.js"></script>
    <script type="text/javascript" src="../libs/var.js"></script>
    <script type="text/javascript" src="../libs/common.js"></script>
    <script type="text/template" id="wz_tpl">
    	<div class="detailHeader">
			<div class="headerImg">
				<span class="bigImg">
					<img src="../static/images/shank.png" class="bigImg_shank"/>
					<img src="<%= farm.coverPic %>" alt="" />
				</span>
				<span class="newLocation">
					<img src="../static/images/locationWhite.png" alt="" />
					<%= farm.distance %>km
				</span>
				<span class="renzheng">
					<img id="wz_idCard" src="../static/images/rzName.png" alt="" />
					<img id="wz_phoneCard" src="../static/images/rzIphone.png" alt="" />
					<img id="wz_bankCard" src="../static/images/rzCard.png" alt="" />
				</span>
				<span class="touxiang">
					<img src="<%= celebrity.headPic %>" alt="" />
				</span>
			</div>
			<div class="headerText">
				<span><%= farm.name %></span>
				<p><%= farm.recReason %></p>
			</div>
		</div>
		<div class="wz_detailTab">
			<div class="swiper-pagination"></div>
			<div class="wz_separate"></div>
			<div class="swiper-container">
				<div class="swiper-wrapper">
					<div class="swiper-slide">
						<!--大宗供应-->
						<ul class="supplyList">
							<% for(var i=0;i<goods.length;i++) { %>
							<a href="../bigSupply/bs_detail.html?id=<%= goods[i].goodsId %>">
							<li>
						        <div class="left_pic" goodsId="<%= goods[i].goodsId %>">
						        	<img src="<%= goods[i].mainImage[0] %>" alt=""/>
						        	<span><%= goods[i].supplyStatus %></span>
						        </div>
						        <div class="right_text">
						            <p class="goodsInfo">
						            	<i class="sdd_tag"><%= goods[i].goodsClassName %><em class="jiantou"></em></i>
						            	<%= goods[i].goodsName %>
						            </p>
						            <div class="supplyGoods firstTop">
						            	<span class="area">
											<img src="../static/images/farm.png" alt=""/>
											<i><%= farm.name %></i>
										</span>
										<span class="location">
											<img src="../static/images/location.png" alt=""/>
											<i><%= farm.distance %>km</i>
										</span>
						            </div>
						            <div class="supplyGoods">
						                <span class="total">总量：<%= goods[i].totalSupply %><%= goods[i].unit %></span>
						            </div>
						            <div class="supplyGoods">
						            	<span class="qipi">起批：<%= goods[i].rangeBegin %><%= goods[i].unit %></span>
						            	<% if((goods[i].price&&goods[i].price!='0.00'&&goods[i].price!='0.0'&&goods[i].price!='0')|| goods[i].price>0){ %>
						            	<span class="price"><i>¥<%= goods[i].price %></i>元/<%= goods[i].unit %></span>
						            	<% }else{ %>
						            	<span class="price">可议</span>
						            	<% } %>
						            </div>
						        </div>
							</li>
							</a>
							<% } %>
						</ul>
						<!--暂无供应-->
						<div id="noGoods" class="wz_noGoods">
							<img src="../static/images/defaultImg1.png" alt="">
							<div class="wz_noText">农庄暂无供应商品</div>
						</div>
					</div>
					<div class="swiper-slide">
						<!--基本资料-->
						<ul class="wz_ul">
							<li class="wz_jbzl">
								<span class="wz_jbzlL">性质认证</span>
								<span class="wz_jbzlR" id="wz_gsxz"></span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">农庄经营项目</span>
								<span class="wz_jbzlR">
									<% if (farm.tags != null) { %>
										<% for(var i=0;i<farm.tags.length;i++) { %>
											<span><%= farm.tags[i] %></span>
										<% } %>
									<% } else{ %>
										<span>暂无</span>
									<% } %>
								</span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">农庄地址</span>
								<span class="wz_jbzlR wz_address wz_address_havepadding"><%= farm.area %></span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">农庄电话</span>
								<span class="wz_jbzlR" id="wz_tel"><%= farm.telephone %>
									<span class="wz_tel"></span>
								</span>
							</li>
							<!--<div class="wz_separate"></div>-->
							<li class="wz_jbzl">
								<span class="wz_jbzlL">庄主</span>
								<span class="wz_jbzlR">
									<span class="wz_masterText"><%= celebrity.nickName %></span>
									<span class="wz_masterIcon" style="float: right;">
										<img src="<%= celebrity.headPic %>" alt="">
									</span>
								</span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">入驻年限</span>
								<span class="wz_jbzlR">
									<span id="wz_year"><span><%= year %></span>年</span>
									<span id="wz_month"><span><%= month %></span>个月</span>
								</span>
							</li>
							<div class="wz_separate"></div>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">种植面积</span>
								<span class="wz_jbzlR" id="wz_zzmj"><%= farm.acreage %>亩</span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">主要农产品</span>
								<span class="wz_jbzlR" id="wz_zyncp"><%= farm.crop %></span>
							</li>
							<li class="wz_jbzl">
								<span class="wz_jbzlL">年产量</span>
								<span class="wz_jbzlR" id="wz_ncl"><%= farm.yield %>吨</span>
							</li>
							<li class="wz_jbzl wz_cpzz">
								<span class="wz_jbzlL">产品资质</span>
								<span class="wz_jbzlR wz_cpzzR" id="wz_cpzzR"></span>
							</li>
						</ul>
					</div>
					<div class="swiper-slide wz_dtSlide">
						<!--农庄动态-->
						<div class="wz_dt">
							<div class="wz_nodt">
								<img src="../static/images/defaultImg1.png" alt="">
								<div class="wz_noText">农庄还没有发布动态</div>
							</div>
						</div>
					</div>	
					<div class="swiper-slide">
						<!--农庄介绍-->
						<div class="wz_story">
							<!--<div class="wz_storyTitle">农庄故事</div>
							<div class="wz_about">ABOUT</div>-->
							<div id="wz_storyCtn">
								<div class="wz_noStory">
									<img src="../static/images/defaultImg1.png" alt="">
									<div class="wz_noText">农庄还没有故事</div>
								</div>
							</div>
						</div>
						<div class="wz_separate"></div>
						<div class="wz_comment">
							<div class="wz_commentTop">
								<div class="wz_commentTitle">来过、爱过、留下过足迹...</div>
								<div class="wz_commentNum">共有<span><%= commentCount %></span>条评论</div>
								<div class="wz_commentIcons">
									<div class="wz_commentList"></div>
									<div class="wz_allComment" id="wz_allComment">
										<img src="../static/images/allpinglun.png" alt="">
									</div>
								</div>
							</div>
							<!--<div class="wz_noComment">
								<img src="../static/images/defaultImg1.png" alt="">
								<div class="wz_noText">农庄还没有评论</div>
							</div>-->
							<div class="wz_commentTem"></div>
						</div>
					</div>
				</div>
			</div>
		</div>
		<div class="bulktraderdetail_kongss"></div>
		<div class="bulktraderdetail_foot">
			<a href="tel:<%= farm.telephone %>">
				<div class="bulktraderdetail_phone re">
					<img src="../static/images/fqlianxi.png" class="haveMarRight"/>联系电话<i></i>
				</div>
			</a>
			<div class="bulktraderdetail_phone gz guanzhu">
				<img src="../static/images/keep_b.png"/>
				<span>收藏</span>
			</div>
		</div>
    </script>	
	<script type="text/template" id="wz_tpl11">
		<% for(var i=0;i<5;i++) { %>
			<span class="wz_commentIcon">
				<img src="<%= comments[i].headPic %>" alt="">
			</span>
		<% } %>
	</script>
	<script type="text/template" id="wz_tpl12">
		<% for(var i=0;i<comments.length;i++) { %>
			<span class="wz_commentIcon">
				<img src="<%= comments[i].headPic %>" alt="">
			</span>
		<% } %>
	</script>
    <script type="text/template" id="wz_tpl2">
    	<% for(var i=0;i<comments.length;i++) { %>
    		<div class="wz_commentLi">
				<div class="wz_commentLiL">
					<span class="wz_commentLiIcon">
						<img class="wz_commentImg" src="<%= comments[i].headPic %>" alt="">
					</span>
				</div>
				<div class="wz_commentCtn">
					<div class="wz_commentCtnLine1">
						<span class="wz_commentPerson"><%= comments[i].userNickname %></span>
						<span class="wz_commentTime"><%= comments[i].createTime %></span>
					</div>
					<div class="wz_commentCtnLine2"><%= comments[i].content %></div>
					<div class="wz_commentImgs">
						<% for(var j=0;j<comments[i].photos.length;j++) { %>
							<img class="wz_img" src="<%= comments[i].photos[j] %>" alt="">
						<% } %>
					</div>
				</div>
			</div>
    	<% } %>
	</script>
	<script type="text/template" id="wz_tpl3">
		<% for(var i=0;i<messages.length;i++) { %>
	    	<div class="wz_dtCtn">
				<div class="wz_dtL">
					<span class="wz_date"><%= messages[i].day %></span>
					<span class="wz_month"><%= messages[i].month %>月</span>
				</div>
				<div class="wz_dtR">
					<% for(var j=0;j<messages[i].messageList.length;j++) { %>
						<div class="wz_dtRList">
							<div class="wz_dtRListIcon">
								<img src="<%= messages[i].messageList[j].contentMedia %>" alt="">
							</div>
							<div class="wz_dtRListR">
								<span class="wz_dtRListTitle"><%= messages[i].messageList[j].content %></span>
							</div>
						</div>
					<% } %>
				</div>
			</div>
    	<% } %>
	</script>
	<script src="js/yellowPage_detail.js"></script>
</html>